<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        const arr=['郑玮喆',
        '庄云',
        '廖治先',
        '郑文源',
        '戴俊锋',
        '陈昊童',
        '谢金金',
        '占志新',
        '张淑芳',
        '刘永潘',
        '廖柏成',
        '郑宗帅',
        '李韦峰',
        '吴欣燕',
        '陈梅香',
        '陈立智',
        '戴俊锋',
        '戴俊锋',
        '戴俊锋',
        '太君',
        '太君',
        '大佐',
        '大佐',
        '大佐',
        '罗启恒',
        '卢国建',
        '黄柱菘',
        '陈鹏',
        '张耀仁',
        '陈华伟',
        '张正豪',
        '韦仲晓',
        '黄富贵',
        '陆建锋',
        '曾德森',
        '吴文龙',
        '陆利群',
        '黄雄',
        '王世财',
        '张先杰',
        '胡基耀',
        '马鑫涛',
        '李涛',
        '杨凌翔',
        '罗此东',
        '唐皓颖',
        '白婉婷']
        var time=0;
        function huhu(){
            time++;
            var number=Math.ceil(Math.random()*arr.length-1);
            document.getElementById('name').innerText=arr[number]
            console.log(number);
            if(arr[number]=='太君'){
                time=31
            }
            if(time>=30){
                clearInterval(clock)
        }
    }
        function gogo(){
            time=0
            clock=setInterval(huhu,100)
        }
    </script>    
    <div style="text-align:center ; ">
        <button onclick="gogo()" style="width:200px ; height: 200px;"><h1 id="name">开始</h1></button>
    </div>
</body>
</html2